<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>展示</title>
    <style>
        table{
            border-collapse: collapse;
        }
        tr:first-child{
            text-align: center;
        }
        td:last-child{
            text-align: center;
        }
    </style>
</head>
<body>
<a href="{% url 'news:news_add' %}">添加</a>
<form action="{% url 'news:news_show' %}">
    <table border="1">
            <tr>
                <td>ID</td>
                <td>新闻标题</td>
                <td>新闻分类</td>
                <td>操作</td>
            </tr>
            {% for i in data %}
            <tr>
                <td>{{ i.id }}</td>
                <td>{{ i.title }}</td>
                <td>{{ i.fl.typess }}</td>
                <td>
                    <a href="">删除</a>
                    <a href="{% url 'news:news_showw' %}">展示所有新闻</a>
                </td>
            </tr>
            {% endfor %}

    </table>
</form>

</body>
</html>